package com.my.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import lombok.experimental.Accessors;

import java.util.Date;

@Data
@Accessors(chain = true)
public class User {

    @TableId(type = IdType.INPUT)
    private Long id;
    private String password;
    private String name;
    private String phone;
    private String address;
    private Integer sex;
    private Integer type;
    private Long gradeClassId;
    private String major;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createTime;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date updateTime;

    @TableField(exist = false)
    private boolean attendance;
    @TableField(exist = false)
    private boolean rollCall;

    @TableField(exist = false)
    private Long oldId;
    @TableField(exist = false)
    private Long gradeId;

}
